﻿using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace SmartERP.Web.Models
{
    public class Student: Person
    {
        //public int PersonID { get; set; }

        //[MaxLength(50)]
        //[Required(ErrorMessage = "Last name is required.")]
        //[Display(Name = "Last Name")]
        //public string LastName { get; set; }

        //[MaxLength(50, ErrorMessage = "First name cannot be longer than 50 character")]
        //[Column("FirstName")]
        //[Required(ErrorMessage = "First name is required.")]
        //[Display(Name = "First Name")]
        //public string FirstMidName { get; set; }

        //public string FullName
        //{
        //    get { return LastName + ", " + FirstMidName; }
        //}

        [Required(ErrorMessage = "Enrollment date is required.")]
        [Display(Name = "Enrollment Date")]
        [DisplayFormat(DataFormatString = "{0:d}", ApplyFormatInEditMode = true)]
        public DateTime EnrollmentDate { get; set; }

        

        public virtual ICollection<Enrollment> Enrollments { get; set; } 
    }
}